#!/bin/bash

if test -z "${1}"; then
    echo "Usage: ${0} <host>"
    exit
fi

while test -n "${1}"; do
    host=$1
    for file in $(lynx --source "http://${host}/RabbitShare/upload"|grep 'icons/text.gif'|sed 's/.*>\(.*\)<\/a>.*/\1/g'); do
        echo $(lynx --source "http://${host}/RabbitShare/upload/${file}")
    done
    shift
done
